Goto

General Control Statement

Syntax samples

GOTO <label ID>

GOTO LabelA

Description

Jumps to the statement identified by the designated label. A label should follow the normal rules for names except that it is followed by a colon in the logic. GOTO statements may be replaced by IF...THEN...ELSE statements.

Valid In

Any logic.

Components

<label ID>

The name of the label to switch to. Omit the colon on the label name here.

Example

This example shows how a GOTO statement is used to skip over the first two increment statements based on the value of an attribute.

Process Table

Entity

Location

Operation (min)

Box

Receive

IF Attr1>1 THEN GOTO L1

INC V1

INC V2

L1:

INC V3

Routing Table

Blk

Output

Destination

Rule

Move Logic

1

Box

Stores

FIRST 1

MOVE FOR 5

See Also

IF...THEN...ELSE, BREAK, and BREAKBLK.